import { $get } from '@js/request'
import { InputBatchSchema } from '@src/components/schema/inputBatch'

export async function getListRequest (page: number, limit: number): Promise<{ list: InputBatchSchema[], total: number }> {
  const res = await $get('/api/common/input_excel', {
    page,
    limit
  })
  const list: InputBatchSchema[] = res.data.list
  list.forEach((li, i) => {
    li.orderno = (page - 1) * limit + i + 1
  })
  return res.data
}
